From: Florian Müllner Date: Wed, 23 Jan 2019 22:55:12 +0000 (+0100) Subject: panel: Don't allow opening hidden menus via keybindings X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~897^2^2~21 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=c1a6effea003e4d94b9afa2908a063f22888b809;p=gnome-shell.git panel: Don't allow opening hidden menus via keybindings We shouldn't allow toggling menus that aren't supported by the current session mode, but as indicators are hidden rather than destroyed on mode switches, it is not enough to check for an indicator's existence. https://gitlab.gnome.org/GNOME/gnome-shell/issues/851 --- diff --git a/js/ui/panel.js b/js/ui/panel.js index 3ce95a16a..8a6cb7722 100644 --- a/js/ui/panel.js +++ b/js/ui/panel.js @@ -957,8 +957,8 @@ class Panel extends St.Widget { } _toggleMenu(indicator) { - if (!indicator) // menu not supported by current session mode - return; + if (!indicator || !indicator.container.visible) + return; // menu not supported by current session mode let menu = indicator.menu; if (!indicator.actor.reactive)